import { post, get } from '../../http/axios'

export default {
    namespaced: true,
    state: {
        hospitals: {}
    },
    mutations: {
        set_hospital(state, val) {
            state.hospitals = val
        }
    },
    actions: {
        async findHos({ commit }, params) {
            let res = await get('/hospital/pageQuery', params)
            commit('set_hospital', res.data)

        },
        async saveHos({ commit }, params) {
            let res = await post('/hospital/saveOrUpdate', params)
        },
    }
}